{% extends "base.html" %}
{% load staticfiles %}

{% block title %}CiLiBaBa{% endblock %}

{% block metas %}
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
{% endblock %}

{% block styles %}
{{block.super}}
<link rel="shortcut icon" type="image/x-icon" href="{% static 'favicon.ico' %}" />
<link rel="stylesheet" type="text/css" href="{% static 'css/ssbc.css' %}" />
{% endblock %}

{% block navbar %}
<form class="x-sform" method="get" action="/">
<nav class="navbar navbar-default " role="navigation">
    <div class="container">
        <div class="navbar-header">
            <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
            <span class="sr-only">Toggle navigation</span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            </button>
            <a title="磁力巴巴 收录最快的DHT搜索引擎" alt="shousibaocai" class="navbar-brand" href="{% url 'index' %}">CiLiBaBa</a>
        </div>
        <div class="navbar-collapse collapse">
            <ul class="nav navbar-nav">
                <li class="{% ifequal request.path '/' %}active{%endifequal%}"><a href="{% url 'index' %}">Magnet Search</a></li>
                <li class="{% ifequal request.path '/top/' %}active{%endifequal%}"><a href="{% url 'top_index' %}">Top</a></li>
            </ul>

            {% if request.path != '/' %}
            <div class="navbar-form x-searchbar navbar-left">
                <div class="input-group">
                    <input type="text" autocomplete="off" class="form-control x-kw" name="s" value="{{keyword}}" placeHolder="Movies, actors...">
                    <span class="input-group-btn">
                    <button class="btn btn-default" type="submit"><span class="glyphicon glyphicon-search"></span></button>
                    </span>
                </div><!-- /input-group -->
            </div>
            {% endif %}
        </div>
    </div>
</nav>
</form>

<div class="alert alert-info" style="text-align:center; margin-top: -20px;">
    CiLiBaBa (www.cilibaba.com) is a website for searching <b>anything</b> you want :D
</div>
{% endblock %}

{% block content %}
<div class="container">
    <p>No content</p>
</div>
{% endblock %}

{% block scripts %}
<script src="{% static 'js/jquery-1.11.0.min.js' %}"></script>
<script src="{% static 'js/bootstrap.min.js' %}"></script>
<script src="{% static 'js/bootstrap-typeahead.min.js'%}"></script>
<script src="{% static 'js/ssbc.js' %}"></script>
{% endblock %}

